Port Privacy Policy Command - #58
Closed
belofe wants to merge 3 commits into
Closed
Conversation
added 2 commits
February 3, 2026 16:21
Contributor
Reviewer's GuideAdds a new Privacy cog extension that exposes a /privacy slash command to display the bot’s privacy policy via an ephemeral embedded message, and wires it up for cog-based loading. Sequence diagram for the new /privacy slash command flowsequenceDiagram
actor User
participant DiscordClient
participant DiscordAPI
participant Bot as DiscordBot
participant Privacy as PrivacyCog
User->>DiscordClient: Trigger /privacy
DiscordClient->>DiscordAPI: Send interaction
DiscordAPI->>Bot: POST interaction payload
Bot->>Privacy: Dispatch to privacy handler
Privacy->>Privacy: Build privacy Embed
Privacy->>Bot: interaction.response.send_message(embed, ephemeral=True)
Bot->>DiscordAPI: Send ephemeral response
DiscordAPI->>DiscordClient: Deliver ephemeral message
DiscordClient->>User: Show privacy policy embed
Updated class diagram for the Privacy cog extensionclassDiagram
class commands_Cog
class commands_Bot
class Privacy {
- bot: commands_Bot
- log: logging_Logger
+ __init__(bot: commands_Bot)
+ privacy(interaction: discord_Interaction) async
}
Privacy ..|> commands_Cog
commands_Bot o-- Privacy
class privacy_extension_module {
+ setup(bot: commands_Bot) async
}
privacy_extension_module ..> Privacy : add_cog(Privacy(bot))
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Contributor
There was a problem hiding this comment.
Hey - I've found 1 issue, and left some high level feedback:
- In the
Data Accessembed field, the concatenated string for "Your information is never shared with third parties" and "or used for marketing purposes." is missing a space, so one of the literals should end with a space to avoid rendering aspartiesor. - The privacy policy content (including the "Last updated" date) is fully hard-coded in the cog; consider centralizing this text in a config or constants module so it can be updated without changing code and redeploying the bot.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- In the `Data Access` embed field, the concatenated string for "Your information is never shared with third parties" and "or used for marketing purposes." is missing a space, so one of the literals should end with a space to avoid rendering as `partiesor`.
- The privacy policy content (including the "Last updated" date) is fully hard-coded in the cog; consider centralizing this text in a config or constants module so it can be updated without changing code and redeploying the bot.
## Individual Comments
### Comment 1
<location> `capy_discord/exts/tools/privacy.py:79-80` </location>
<code_context>
+ "• Event participation management\n"
+ "• Academic program coordination\n"
+ "• Communication within organizations\n\n"
+ "Your information is never shared with third parties"
+ "or used for marketing purposes."
+ ),
+ inline=False,
</code_context>
<issue_to_address>
**issue (bug_risk):** String concatenation here drops the space between "parties" and "or".
These adjacent literals are concatenated as-written, producing `"third partiesor used"`. Add a space to either the end of the first string or the start of the second (e.g., `"third parties "` or `" or used for marketing purposes."`).
</issue_to_address>Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Comment on lines
+79
to
+80
| "Your information is never shared with third parties" | ||
| "or used for marketing purposes." |
Contributor
There was a problem hiding this comment.
issue (bug_risk): String concatenation here drops the space between "parties" and "or".
These adjacent literals are concatenated as-written, producing "third partiesor used". Add a space to either the end of the first string or the start of the second (e.g., "third parties " or " or used for marketing purposes.").
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added privacy cog from deprecated bot to discord bot.
Summary by Sourcery
New Features: